@extends('layouts.app')

@section('title', '加入我们')

@section('header')
    @include('layouts.header-two')
@stop

@section('content')
    <div class="wrapper">
        <div class="banner">
            <img src="{{ asset('statics/images/QQ20171205-165646@2x.jpg') }}" alt="" />
        </div>
        <div class="wrapper-inner">
            <div class="container">
                <div class="title">
                    <p>JOIN US</p>
                    <h3>诚聘英才</h3>
                    <div class="line1"></div>
                </div>
                <div class="join-wrapper">
                    <div class="row">
                        <div class="col-md-2">
                            <div class="join-ls">
                                @if(!empty($sectors))
                                    @foreach($sectors as $key => $sector)
                                        <div class="join-section">
                                            <h3>{{ $sector->name }}</h3>
                                            <ul>
                                                @foreach($sector->jobs as $item)
                                                    <li @if($job_id == $item->id) class="ons" @endif>
                                                        <a href="{{ route('join', ['job_id' => $item->id]) }}">{{ $item->name }}</a>
                                                    </li>
                                                @endforeach
                                            </ul>
                                        </div>
                                    @endforeach
                                @endif
                            </div>
                        </div>
                        <div class="col-md-10">
                            <div class="join-rs">
                                @if($job)
                                <h2 class="join-title">招聘详情</h2>
                                <div class="join-content">
                                    {!! $job->describe !!}

                                    <br>
                                    <div class="join-tab">
                                        <h3 class="join-tab-title">其他说明：</h3>
                                        {{--@if(explode($job->explain, ','))--}}
                                        @foreach($explains as $k => $explain)
                                            <span class="description">{{ $explain }}</span>
                                        @endforeach
                                    </div>
                                    <div class="join-tab">
                                        <h3 class="join-tab-title">联系方式：</h3>

                                        {!! $job->telephone !!}
                                    </div>
                                </div>
                                @endif
                            </div>
                        </div>
                    </div>
                    {{--<div class="join-declaration">--}}
                        {{--<h2 class="declaration-title">招聘声明：</h2>--}}
                        {{--<p></p>--}}
                    {{--</div>--}}
                </div>
            </div>
        </div>
    </div>
@stop

@section('footer')
    @include('layouts.footer')
@stop

@section('script')
    <script>
        $(function(){
            var h1=$(".join-ls").height();
            var h2=$(".join-rs").height();
            if(h1>h2){
                $(".join-rs").height($(".join-ls").height());
            }else{
                $(".join-ls").height($(".join-rs").height());
            }
        })
    </script>
@stop